﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Windows.Forms;

namespace EmbeddedSharp.Scripting.Visualization {
    static class Program {
        /// <summary>
        /// The main entry point for the application.
        /// </summary>
        [STAThread]
        static void Main(string[] args) {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            if (args.Length == 0) {
                Application.Run(new PlotView());
            } else {
                if (!System.IO.File.Exists(args[0])) {
                    throw new System.IO.FileNotFoundException(args[0]);
                }

                Application.Run(new PlotView(args[0]));
            }
        }
    }
}
